
[dbo].[OrderProductCrossSellLookup]
CREATE TABLE [dbo].[OrderProductCrossSellLookup]
(
[OrderProductID] [int] NOT NULL,
[CrossSellOrderProductID] [int] NOT NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[OrderProductCrossSellLookup] ADD CONSTRAINT [PK_OrderProductCrossSellLookup] PRIMARY KEY CLUSTERED ([OrderProductID], [CrossSellOrderProductID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[OrderProductCrossSellLookup] ADD CONSTRAINT [FK_OrderProductCrossSellLookup_OrderProduct] FOREIGN KEY ([OrderProductID]) REFERENCES [dbo].[OrderProduct] ([OrderProductID]) ON DELETE CASCADE ON UPDATE CASCADE
GO
ALTER TABLE [dbo].[OrderProductCrossSellLookup] ADD CONSTRAINT [FK_OrderProductCrossSellLookup_OrderProduct_CrossSell] FOREIGN KEY ([CrossSellOrderProductID]) REFERENCES [dbo].[OrderProduct] ([OrderProductID])
GO